package com.dj.shop.service;

import com.dj.shop.model.GoodsFlow;
import com.dj.shop.model.OrderFlow;
import com.dj.shop.model.OrderWrapper;

import java.util.List;
import java.util.Map;

/**
 * @author renshp
 * @Title: OrderService
 * @Description: TODO
 * @date 2019/3/5
 */
public interface OrderService {

    /***
     * 新增订单
     * @param orderFlow
     * @param goodsFlowList
     * @return
     */
    int addOrder(OrderFlow orderFlow, List<GoodsFlow> goodsFlowList);

    /***
     * 更新订单状态
     * @param orderId
     * @param orderStatus
     * @return
     */
    int updateOrderStatus(int orderId, String orderStatus);

    /***
     * 根据id获取订单信息
     * @param orderNo
     * @return
     */
    OrderFlow queryOrderById(int orderNo);

    /***
     * 根据订单id查询订单商品明细
     * @param orderNo
     * @return
     */
    List<GoodsFlow> queryGoodsListByOrderNo(int orderNo);

    /***
     * 组合查询
     * @param orderes
     * @return
     */
    List<OrderWrapper> queryOrder(Map<String,Object> orderes);
}
